import{setTi,delTi,setTi1,setTi2,delTi1,delTi2}from'@/utils/auth.js'
const state={
    Ti:[],
    Mysjlist:{},
}
const mutations = {
	SET_TI:(state,ti)=>{
    state.Ti = ti
    delTi()
    setTi(ti)
    // if(ti.length<=5000){
    //   setTi(ti)
    // }else if(ti.length>5000&&ti.length<=10000){
    //   setTi(ti.slice(0,5000))
    //   setTi1(ti.slice(5000,10000))
    // }else{
    //   setTi(ti.slice(0,5000))
    //   setTi1(ti.slice(5000,10000))
    //   setTi2(ti.slice(10000))
    // }
  },
  DEL_TI:(state,ti)=>{
    state.Ti = []
    delTi()
    delTi1()
    delTi2()
  },
  SET_MYSJLIST:(state,Mysjlist)=>{
    state.Mysjlist = Mysjlist
  }
}
const actions = {
  commitTi({
    commit
  }, data) {
    commit('SET_TI',data)
    
  }
}
export default {
  state,
  mutations,
  actions
}